package com.zl.learning.object.proxy;

import java.lang.reflect.Proxy;

public class Main {
    public static void main(String[] args) {
        IWorker worker = (IWorker) Proxy.newProxyInstance(Worker1.class.getClassLoader(), Worker1.class.getInterfaces(), new WorkProxy());
        worker.say("孙丽");
        worker.work("孙瑞", 25);
    }
}
